<template>
  <div class="report" />
</template>

<script>
import echarts from 'echarts';
export default {

  data() {
    return {

    };
  },
  mounted() {
    this.updateAllChart();
    window.addEventListener('resize', this.resizeAllChart);
  },
  beforeDestroy() {
    window.removeEventListener('resize', this.resizeAllChart);
  },
  methods: {
    updateAllChart() {
      this.initAbilityAnalysisChart();
    },
    resizeAllChart() {
      if (this.abilityAnalysisChart) this.abilityAnalysisChart.resize();
    },
    initAbilityAnalysisChart() {
      let i = -1;
      const option = {
        title: {
          text: ''
        },
        tooltip: {
          trigger: 'item',
          formatter: params => {
            var relVal = params.name;
            this.indicator.forEach((v, vIndex) => {
              relVal += `<br/>${v.text} : ${this.radarProportion[vIndex]}%`;
            });
            return relVal;
          }
        },
        radar: [
          {
            indicator: this.indicator,
            name: {
              color: 'rgba(255, 255, 255, 1)',
              formatter: (value, b) => {
                i++;
                if (!this.analysisChartData[i]) {
                  this.analysisChartData[i] = '0%';
                }
                return `${value}${this.analysisChartData[i]}`;
                // return `${value}`;
              }
            },
            center: this.indicator.length === 4 ? ['50%', '37%'] : ['42%', '32%'],
            radius: 75,
            splitNumber: 5, // 雷达图圈数设置
            // 设置雷达图中间射线的颜色
            axisLine: {
              lineStyle: {
                color: 'rgba(91, 161, 255, 0.20)'
              }
            },
            splitArea: {
              // 设置图表颜色，show的值为true
              show: true,
              areaStyle: {
                color: ['#00133a', '#041d4b', '#00133a', '#041d4b']
              }
            },
            splitLine: {
              // 网格颜色设置
              show: true,
              lineStyle: {
                width: 1,
                color: 'rgba(44, 121, 225, 0.10)'
              }
            }
          }
        ],
        series: [
          {
            type: 'radar',
            areaStyle: {},
            data: [
              {
                value: this.radarProportion,
                name: '能力分析',
                areaStyle: { color: 'rgba(0, 238, 255, 0.20)' }, // 雷达覆盖区域背景颜色
                itemStyle: {
                  normal: {
                    color: 'rgba(0, 238, 255, 1)', // 背景颜色，还需设置areaStyle,
                    // borderColor:'red',
                    lineStyle: {
                      color: 'red' // 边框颜色
                    }
                  }
                }
              }
            ]
          }
        ]
      };
      this.abilityAnalysisChart = echarts.init(this.$refs.radarChart);
      this.abilityAnalysisChart.setOption(option);
    }
  }
};
</script>

<style lang="scss" scoped>
.enforcement_effectiveness {
  position: relative;
  padding: 0 20px;
  margin-bottom: 10px;
  border: 1px solid rgba(18, 208, 255, 0.5);
  border-bottom: 4px solid rgba(18, 208, 255, 1);
  border-radius: 2px;
  background: linear-gradient(180deg, rgba(7, 44, 107, 0.3), rgba(7, 44, 107, 0.9) 100%);
}
.box_title {
  width: 100%;
  margin: 38px 0 10px 0;
  div {
    text-align: center;
    width: 103px;
    height: 33px;
    line-height: 33px;
    background-color: rgba(0, 75, 177, 0.6);
    color: rgba(65, 204, 242, 1);
  }
}
.outer_border {
  width: 100%;
  border: 1px solid rgba(33, 225, 239, 1);
  border-radius: 8px;
}
.row1_box {
  width: 100%;
  height: 244px;
}
.row2_box {
  height: 385px;
}

.enforcement_content {
  text-align: center;
  > div {
    // padding:20px 30px 0 30px;
    width: 48%;
  }
  > div:nth-child(2) {
    width: 1px;
    height: 88px;
    padding: 0;
    margin-top: 10px;
    border: 0.5px solid rgba(28, 124, 255, 0.5);
  }
  .content_result {
    height: 58px;
    font-size: 48px;
    color: rgba(38, 255, 255, 1);
  }
  .content_fl {
    font-size: 18px;
  }
}
.enforcement_estimate {
  text-align: center;
  margin-top: 15px;
}
.content_text {
  padding: 0 15px;
  text-align: left;
  border: 1px solid transparent;
  .more {
    cursor: pointer;
    color: rgba(33, 225, 239, 1);
  }
}
.container-title {
  position: absolute;
  left: 50%;
  transform: translateX(-50%) translateY(-50%); /* 移动元素本身50% */
  width: 480px;
  font-size: 20px;
  font-weight: Bold;
  text-align: center;
  line-height: 42px;
  background: url('../../../assets/imgs/workScheduling/title-bg.png') no-repeat;
  background-size: 100%;
}
.ability_analysis_box {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  .ability_analysis {
    width: 200px;
    height: 100px;
    border: 1px solid rgba(33, 225, 239, 1);
    border-radius: 8px;
    &_title {
      display: flex;
      align-items: center;
      margin: 15px 0 15px 15px;
      > div {
        margin-right: 10px;
      }
      > div:nth-child(1) {
        width: 5.99px;
        height: 12.99px;
      }
    }
    &_score {
      font-size: 18px;
      line-height: 22px;
    }
    &_divide {
      font-size: 14px;
    }
  }
  > div {
    margin: 0px 10px 45px 10px;
  }
}
.ability_analysis_container {
  position: relative;
  border: none;
  .radar_chart {
    position: absolute;
    left: 50%;
    top: -10%;
    transform: translate(-50%);
  }
}
.case_handling_ability {
  width: 100%;
  height: 101px;
  padding-top: 20px;
  // >div{
  //   margin-right: 40px;
  // }
  &_conten {
    width: 100%;
    height: 280px;
    border-radius: 8px;
    padding: 10px 10px;
  }
}
.case_content_box {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  .case_content {
    width: 47%;
    height: 96px;
    margin-top: 10px;
    padding: 10px;
    background-color: #03276e;
    border-radius: 4px;
    > div {
      margin: 3px 0;
    }
    > div:nth-child(2) {
      color: #26ffffff;
      font-size: 20px;
      height: 24px;
    }
    ::v-deep .el-progress-bar__inner {
      background-color: #26ffffff;
    }
    ::v-deep .el-progress-bar__outer {
      background-color: #044097ff;
    }
    ::v-deep .el-progress__text {
      color: #26ffffff;
    }
  }
}
.big_case_chart {
  width: 100%;
  height: 210px;
  margin-top: 15px;
}
.human_resources {
  &_title {
    width: 100%;
    height: 78px;
    padding-top: 20px;
    > div {
      margin-right: 40px;
    }
    > div:nth-child(3),
    div:nth-child(4) {
      margin-right: 10px;
    }
  }
  &_chart {
    width: 100%;
    height: 305px;
    border-radius: 8px;
    div {
      width: 100%;
      height: 100%;
    }
  }
}
.row2_content_title {
  span {
    font-size: 20px;
    color: rgba(38, 255, 255, 1);
  }
  ::v-deep .el-form-item__label {
    color: #ffffffff;
  }
}
.case_star {
  margin: 0 auto;
  width: 98%;
  height: 51px;
  background: url('../../../assets/imgs/workScheduling/case_star_bg.png') no-repeat;
  background-size: 100%;
  img {
    width: 57px;
    height: 38px;
    vertical-align: middle;
    margin-right: 10px;
  }
  > div:last-child {
    width: 54px;
    margin-left: 15px;
    color: #26ffffff;
    font-size: 18px;
  }
}
.distinguish_xnpj {
  width: 668px;
  display: flex;
  justify-content: space-around;
  padding: 0 40px;
  background: url('../../../assets/imgs/workScheduling/xnpj_bg.png') no-repeat;
  background-size: 100%;
  background-position: 10% 99%;
  border: 1px solid transparent;
  > div {
    margin-top: 50px;
  }
  > div:first-child {
    width: 208.68px;
    height: 129.74px;
    background: url('../../../assets/imgs/workScheduling/xnpj_pm_bg.png') no-repeat;
    background-size: cover;
  }
  > div:last-child {
    width: 310.27px;
    height: 123px;
    padding: 15px;
    background: url('../../../assets/imgs/workScheduling/xnpj_text-bg.png') no-repeat;
    background-size: cover;
  }
  &_content {
    display: flex;
    justify-content: center;
    text-align: center;
    > div {
      width: 60px;
      height: 70px;
      margin-top: 12px;
    }
    .xnpj_divider {
      width: 1px;
      height: 59px;
      background: rgba(0, 199, 213, 0.33);
      margin: 20px 18px 0 10px;
    }
    .size-30 {
      font-size: 30px;
    }
  }
}
.text_description {
  color: #ffff;
}
.contaner_box {
  position: relative;
}
.divider,
.divider2,
.divider3 {
  position: absolute;
  top: 20%;
  width: 1px;
  background-color: rgba(28, 124, 255, 0.3);
}
.divider {
  left: 105%;
  height: 311.32px;
}
.divider2 {
  left: 108%;
  height: 208.43px;
}
.divider3 {
  left: 102.4%;
  height: 208.43px;
}
.axis-tip2 {
  display: none;
  position: absolute;
  padding: 5px 10px;
  font-size: 12px;
  line-height: 18px;
  color: #ffff;
  background: #0b1e4e;
  // box-shadow: 0 1px 4px 0 rgba(0, 0, 0, 0.2);
  border-radius: 4px;
}

.all_box_bg {
  background-color: rgba(4, 29, 77, 1);
}
.color1 {
  color: rgba(33, 225, 239, 1);
}
.color2 {
  color: rgba(239, 133, 40, 1);
}
.color3 {
  color: rgba(162, 101, 254, 1);
}
.color4 {
  color: rgba(246, 233, 47, 1);
}
.bg_color1 {
  background-color: rgba(33, 225, 239, 1);
}
.bg_color2 {
  background-color: rgba(239, 133, 40, 1);
}
.bg_color3 {
  background-color: rgba(162, 101, 254, 1);
}
.bg_color4 {
  background-color: rgba(246, 233, 47, 1);
}

.fonstsize_20 {
  font-size: 20px;
}

.color-FF26FFFF {
  color: rgba(38, 255, 255, 1);
  ::v-deep span {
    font-size: 14px;
  }
}
</style>
